import { postRequest, getRequest, putRequest, delRequest } from '/@/lib/axios';

const baseUrl = "/api/plat/collectBox"

export const iotApi = {

  /**
   * 分页查询  @author  hzw
   */
  queryPage: (param) => {
    return getRequest(baseUrl + '/page', param);
  },

  queryList: (param) => {
    return getRequest(baseUrl + '/list', param);
  },

  /**
   * 增加  @author  hzw
   */
  add: (data) => {
    return postRequest(baseUrl, data);
  },

  /**
   * 修改  @author  hzw
   */
  update: (data) => {
    return putRequest(baseUrl, data);
  },

  /**
   * 删除  @author  hzw
   */
  delete: (id) => {
    return delRequest(baseUrl + "/" + id);
  },

};
